/*
 * @Author: your name
 * @Date: 2021-10-21 14:53:46
 * @LastEditTime: 2021-11-10 17:19:04
 * @LastEditors: Please set LastEditors
 * @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
 * @FilePath: \my_app\lib\main.dart
 */
import 'package:flutter/cupertino.dart';
import 'package:flutter/material.dart';
import 'package:my_app/widgets/base/fonts/my_icons_icons.dart';

void main() {
  runApp(const MyApp());
}

class MyApp extends StatelessWidget {
  const MyApp({Key? key}) : super(key: key);

  @override
  Widget build(BuildContext context) {
    // CuperinoApp
    return CupertinoApp(
      home: CupertinoPageScaffold(
        navigationBar: CupertinoNavigationBar(),
        child: SafeArea(
          child: Center(
            child: Column(
              mainAxisAlignment: MainAxisAlignment.center,
              // crossAxisAlignment: CrossAxisAlignment.center,
              children: [
                CupertinoTextField(
                  prefix: Icon(
                    MyIcons.fav,
                    color: Colors.red,
                    size: 26,
                  ),
                ),
                CupertinoTextField(
                  prefix: Icon(
                    // Icons.lock,
                    MyIcons.person,
                    color: Colors.red,
                  ),
                ),
                CupertinoButton(
                  child: Text('登录'),
                  onPressed: () {
                    print('onPressed');
                  },
                ),
                // Container(
                //   // 1.padding
                //   // padding: const EdgeInsets.only(top: 110),
                //   child: Text(
                //     'tomic社區',
                //     textDirection: TextDirection.ltr,
                //   ),
                // ),
              ],
            ),
          ),
        ),
      ),
    );
    // return MaterialApp(
    //   home: Scaffold(
    //     appBar: AppBar(),
    //     body: Container(
    //       child: Text(
    //         'tomic社区',
    //         textDirection: TextDirection.ltr,
    //       ),
    //     ),
    //   ),
    // );
  }
}
